package ATMDispenser;

public class ATMNotesDispenser implements NotesHandler{
	
	NotesHandler handler;
	
	public ATMNotesDispenser() {
		TwentyHandler n20 = new TwentyHandler();
		TenHandler n10 = new TenHandler();
		FiveHandler n5 = new FiveHandler();
		
		setHandler(n20);
		n20.setNextHandler(n10);
		n10.setNextHandler(n5);
	}
	
	public void setHandler(NotesHandler h) {
		this.handler = h;
	}
	
	public void dispense(int amount) {
		handler.issueNotes(amount);
	}

	public void setNextHandler(NotesHandler nextHandler) {
		// TODO Auto-generated method stub
		
	}

	public void issueNotes(int amount) {
		// TODO Auto-generated method stub
		
	}
}
